Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Prepare command with bundle exec using SSH prefixes #16

Merged
merged 4 commits into from
Nov 23, 2013
Merged

Conversation

kirs
Copy link
Member

@kirs kirs commented Nov 19, 2013

Here is the first implementation using SSHKit prefixes: capistrano/sshkit#45

@@ -33,6 +33,9 @@ Configurable options, shown here with defaults:
set :bundle_without, %w{development test}.join(' ')
set :bundle_binstubs, -> { shared_path.join('bin') }
set :bundle_roles, :all
set :bundle_bins, %w(gem rake ruby)

By default, the plugin adds `bundle exec` prefix to common executables listed in `bundle_bins` option. You can add any custom executable to this list.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Maybe we should give an example on how to add an additional binary?
set :bundle_bins, fetch(:bundle_bins).push %w(my_new_binary) or something similar?

Because I think rewriting all existing bins to only add a single one seems a bit too complex to me...

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That'd be sane imho. Is there really no way to get Bundler to list binaries provided by the gems in the bundle? That seems insane.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

RubyGems 2.2 is going to do something related - removing the need for bundle exec...
There is also the rubygems-bundler gem - as already mentioned.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sure, I'll fix the README.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@Kriechi fixed.

@Kriechi
Copy link
Contributor

Kriechi commented Nov 22, 2013

As mentioned, RubyGems will provide something like auto-bundle exec.
See rubygems/rubygems@a38032c#diff-f4e766ece0d5ef4b86a06af10d65dc37

Now the question is, when RubyGems 2.2 will be released, and IF capistrano-* should work with older versions too.
@leehambley @kirs @seenmyfate

@leehambley
Copy link
Member

I think we have to support the old one, imagine how long it'll take to get RubyGems 2.2 into all the distros.

I'm sure we could add something into capistrano-bundler to check the rubygems version, and warn if the gem is not needed anymore.

@kirs
Copy link
Member Author

kirs commented Nov 22, 2013

I don't see big reasons to care about Rubygems 2.2 in this release because even after 2.2 is out, it will still have backward compatibility with bundle exec.

@kirs
Copy link
Member Author

kirs commented Nov 22, 2013

I'm sure we could add something into capistrano-bundler to check the rubygems version, and warn if the gem is not needed anymore

agree! PRs will be appreciated 😃

end
end

before 'deploy:updated', 'bundler:install'
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

just to be picky - one space should be enough.

@Kriechi
Copy link
Contributor

Kriechi commented Nov 23, 2013

@kirs could you please rebase to current master. I'm getting version conflicts because this branch believes it is version 0.0.1, but the capistrano-rails gem depends on 1.0.0.

Then I can test the new SSHKit prefix stuff.

@kirs
Copy link
Member Author

kirs commented Nov 23, 2013

$ git rebase master
Current branch sshkit-prefixes is up to date.

@Kriechi
Copy link
Contributor

Kriechi commented Nov 23, 2013

Ehm - the network shows something different:
https://github.com/capistrano/bundler/network

(is your local master up-to-date, maybe try pulling your master...)

Or am I missing something here?

@kirs
Copy link
Member Author

kirs commented Nov 23, 2013

Sorry, my fault. Now it's rebased.

@Kriechi
Copy link
Contributor

Kriechi commented Nov 23, 2013

👍 It works!
Good to merge!

kirs added a commit that referenced this pull request Nov 23, 2013
Prepare command with `bundle exec` using SSH prefixes
@kirs kirs merged commit 15dc06b into master Nov 23, 2013
@kirs kirs deleted the sshkit-prefixes branch November 23, 2013 12:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants